package cn.bytepulse.web.admin.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @author jiejiebiezheyang
 * @since 2024-03-02 22:00
 */
@TableName(value = "sys_log")
@Data
public class SysLog implements Serializable {
    @Serial
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
    /**
     * 日志id
     */
    @TableId(type = IdType.AUTO)
    private Integer id;
    /**
     * 接口uri
     */
    private String uri;
    /**
     * 接口名称
     */
    private String apiName;
    /**
     * http请求方式
     */
    private String httpMethod;
    /**
     * 查询参数
     */
    private String queryParams;
    /**
     * 请求体参数
     */
    private String bodyParams;
    /**
     * 响应结果
     */
    private String responseResult;
    /**
     * 执行的方法
     */
    private String method;
    /**
     * 请求时间戳
     */
    private Date requestTime;
    /**
     * 请求ip
     */
    private String requestIp;
    /**
     * 用户id
     */
    private Integer userId;
    /**
     * 请求耗时
     */
    private Long cost;
    @TableField(exist = false)
    private Date timeFrom;
    @TableField(exist = false)
    private Date timeTo;
    @TableField(exist = false)
    private List<String> ss;
}